#ifndef TIANYU_PLATFORM_PROXY_CLIENT_H_
#define TIANYU_PLATFORM_PROXY_CLIENT_H_

#include "../share/proxy_head.h"
#include "../share/common_define.h"

#include "../share/jsonmessage.h"
#include "../share/common_singleton.h"
#include "../share/server_base.h"
#include "../share/proxy_client.h"
#include "../share/client_base.h"
#include "../share/net_msg_transfer.h"

class CPlatformProxyClient 
	:public ::common::CClientBase
	, public ::common::CSingleton< CPlatformProxyClient >
{
public:
	CPlatformProxyClient();

	~CPlatformProxyClient();

	virtual int32_t InitializeServer(int service_type, int service_id);
	virtual int32_t Finalize();

	virtual int32_t SendMsg(common::CProxyHead& proxy_head, const std::string& msg);
	int32_t SendMsgAddHead(common::CProxyHead& proxy_head, const std::string& msg);

	void SendRegisterPlatformProxyService();

	//void CheckPingTime( );
public:
	virtual bool on_msg(uint32_t id);
	virtual void OnConnect();

private:
	int 			service_id_;
	int				service_type_;

};

#endif



